<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html>
	<head>
		<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
		<title>Data Manipulate Test</title>
		<script src="../JSTest/src/jstest.js"></script>
		<script src="../../src/kekule.js?min=false"></script>
		<script>
			var AtomCreateTestCase = JSTest.TestCase({
					name: 'Atom Create Test',
					init: function () {
			      // this is called only once, before any tests are run
			    },
					setup: function()
					{
					},
					cleanup: function()
					{
					},
					teardown: function () {
        		// this is called only once, after all tests have been run
    			},
					testAtomCompareValue: function()
					{
						var atomSymbols = ['H', 'H', 'C', 'C', 'O', 'N', 'Cl', 'H', 'C'];
						var massNumbers = [1, 1, 12, 13, 16, 14, 35, 2, 12];
						var charges = [-3, 1, 2, -1, -4, 0, -1, 0, 0];
						var atoms = [];
						var compareValues = [];
						for (var j = 0; j < 100; ++j)
						{
							for (var i = 0, l = atomSymbols.length; i < l; ++i)
							{
								atoms[i] = new Kekule.Atom(atomSymbols[i], massNumbers[i]);
								atoms[i].setCharge(charges[i]);
								compareValues[i] = Kekule.UnivChemStructObjComparer.getNodeCompareValue(atoms[i]);
							};
						}

						for (var i = 0, l = compareValues.length; i < l; ++i)
							console.log(compareValues[i].toString(16));
						/**
						this.assertEqual(atoms[0].getAtomicNumber(), 8);
						this.assertEqual(atoms[0].getMassNumber(), null);
						atoms[1].setMassNumber(3);
						this.assertEqual(atoms[1].getAtomicNumber(), 1);
						this.assertEqual(atoms[1].getMassNumber(), 3);
						atoms[3].changeIsotope('C', 12);
						this.assertEqual(atoms[3].getAtomicNumber(), 6);
						this.assertEqual(atoms[3].getMassNumber(), 12);
						atoms[6].setSymbol(null);
						this.assertEqual(atoms[6].getAtomicNumber(), null);
						this.assertEqual(atoms[6].getMassNumber(), null);
						**/
					}
				});

			//JSTest.run(true);
			function init()
			{
				var myDiv = document.getElementById('output');
				//JSTest.run(false, JSTest.handlers.HTMLHandler, myDiv);
				JSTest.run(true, JSTest.handlers.FirebugHandler);
				//JSTest.run();
			}
		</script>
	</head>
	<body onload="init()">
		<div id="output"></div>
	</body>
</html>
